<?php
/**
 * Created by PhpStorm.
 * User: zl
 * Date: 2017/7/29
 * Time: 22:08
 */
    require_once('../Common.php');
    require_once('LoanFee.php');

    $loan_fee_id = $_REQUEST['loan_fee_id'];
    $check_fee = $_REQUEST['check_fee'];
    $operator_ID = $_REQUEST['user_id'];
    if(!isset($loan_fee_id) || !isset($check_fee) || !isset($operator_ID)){
        exit(json_encode(array('state'=>0, 'error'=>'POST_ERROR')));
    }
    $l_fee = new LoanFee();
    $r = $l_fee->financeCheckLoanFee($loan_fee_id, $check_fee, $operator_ID);



    $result_array = array();
    if($r){
        $result_array['state'] = 1;
        $result_array['error'] = '';
    }
    else{
        $result_array['state'] = 0;
        $result_array['error'] = 'DB_ERROR';
    }

    echo json_encode($result_array);


?>